#ifndef NETWORK_REQUEST_H
#define NETWORK_REQUEST_H

#include <QObject>


namespace Network {
class Manager;
class Request : public QObject
{
    Q_OBJECT
public:
    enum Error {
        AbortedError,
        NetworkError
    };

    explicit Request(QObject *parent = 0);

public:
    virtual bool post(Manager *manager) = 0;
    virtual void abort() = 0;

signals:
    void failed(Request *request, Error error, QString message);
};

}
#endif // NETWORK_REQUEST_H
